// 表单校验规则由 schema2code 生成，不建议直接修改校验规则，而建议通过 schema2code 生成, 详情: https://uniapp.dcloud.net.cn/uniCloud/schema



const validator = {
	"name": {
		"rules": [{
				"required": true
			},
			{
				"format": "string"
			}
		],
		"label": "产品名称"
	},
	"keywords": {
		"rules": [{
			"format": "string"
		}],
		"label": "关键字"
	},
	"goods_summary": {
		"rules": [{
			"format": "string"
		}],
		"label": "产品描述"
	},
	"goods_thumb": {
		"rules": [{
				"required": true
			},{
				"format": "string"
			},
			{
				"pattern": "^(http://|https://|/|./|@/)\\S"
			}
		],
		"label": "缩略图"
	},
	"goods_imgs": {
		"rules": [{
				"format": "array"
			}
		],
		"label": "产品详情图"
	},
	"is_on_sale": {
		"rules": [{
				"required": true
			},
			{
				"format": "bool"
			}
		],
		"label": "是否上架"
	}
}



export {
	validator,
}